Page({

  /**
   * 页面的初始数据
   */
  data: {
    imgUrls: [
      '../../images/20141107164412_v284V.jpg',
      '../../images/20141107164412_v284V.jpg',
      '../../images/20141107164412_v284V.jpg',
      '../../images/20141107164412_v284V.jpg',
      '../../images/20141107164412_v284V.jpg'
    ],
    indicatorDots: true,
    autoplay: true,
    interval: 5000,
    duration: 1000,
    flowerList: [{
      imgUrl:'../../images/20141107164412_v284V.jpg',
      price:99.00,
      count:226,
      des:'[四季如春]16朵玫瑰（不含花瓶，下单请备注粉玫还是红玫）'
    },
    {
      imgUrl: '../../images/20141107164412_v284V.jpg',
      price: 99.00,
      count: 226,
      des: '[四季如春]16朵玫瑰（不含花瓶，下单请备注粉玫还是红玫）'
    },
    {
      imgUrl: '../../images/20141107164412_v284V.jpg',
      price: 99.00,
      count: 226,
      des: '[四季如春]16朵玫瑰（不含花瓶，下单请备注粉玫还是红玫）'
    },
    {
      imgUrl: '../../images/20141107164412_v284V.jpg',
      price: 99.00,
      count: 226,
      des: '[四季如春]16朵玫瑰（不含花瓶，下单请备注粉玫还是红玫）'
    }
    ],
    discountCoupon:[{
      "price":'10',
      "realPrice":'298'
    },{
      "price": '30',
      "realPrice": '398'
    },{
      "price": '50',
      "realPrice": '598'
    }]
  },

  /**
   * 生命周期函数--监听页面加载
   */
  onLoad: function (options) {
    console.log('onload');
  },

  /**
   * 生命周期函数--监听页面初次渲染完成
   */
  onReady: function () {
    console.log('onReady')
  },

  /**
   * 生命周期函数--监听页面显示
   */
  onShow: function () {
    console.log('onShow');
  },

  /**
   * 生命周期函数--监听页面隐藏
   */
  onHide: function () {
    console.log('onHide')
  },

  /**
   * 生命周期函数--监听页面卸载
   */
  onUnload: function () {
    console.log('onUnload');
  },

  /**
   * 页面相关事件处理函数--监听用户下拉动作
   * 需要在app.json的window选项中或页面配置中开启enablePullDownRefresh
   */
  onPullDownRefresh: function () {
    console.log('onPullDownRefresh');
  },

  /**
   * 页面上拉触底事件的处理函数
   */
  onReachBottom: function () {
    console.log('onReachBottom');
  },

  /**
   * 用户点击右上角分享
   */
  onShareAppMessage: function () {
    console.log('onShareAppMessage')
  },

  /**
   * 页面滚动触发事件的处理函数
   */
  onPageScroll() {
    console.log('onPageScroll');
  },
  onResize() {
    console.log('onResize');
  },
  onTabItemTap(item) {
    console.log(item.index)
    console.log(item.pagePath)
    console.log(item.text)
  },
  // Event handler.
  viewTap() {
    this.setData({
      text: 'Set some data for updating view.'
    }, function () {
      // this is setData callback
    })
  },
  customData: {
    hi: 'MINA'
  }
})